package chenji.gunapi.untl;

import java.util.HashSet;
import java.util.Set;

import org.bukkit.Location;
import org.bukkit.Material;
import org.bukkit.entity.Entity;
import org.bukkit.entity.LivingEntity;

public class Untl {
	private final Set<Material> ma = new HashSet<Material>();

	public Untl() {
		ma.add(Material.AIR);
		ma.add(Material.WATER);
		ma.add(Material.LONG_GRASS);
		ma.add(Material.IRON_DOOR_BLOCK);
		ma.add(Material.REDSTONE_WIRE);

	}

	public Location getHeadLocation(Entity e) {
		LivingEntity l1 = null;
		if (e instanceof LivingEntity) {
			l1 = (LivingEntity) e;
		} else {
			return e.getLocation();
		}
		return l1.getEyeLocation();
	}

	public Set<Material> getMaterial() {
		return this.ma;
	}

	
}
